/*
 * Created on 28.03.2007
 *
 * To change the template for this generated file go to
 * Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments
 */
package ro.qi.framework.sys.i18n.regional.entities;

import ro.qi.framework.sys.entities.Entity;

/**
 * @author George Pogorelschi
 *
 * To change the template for this generated type comment go to
 * Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments
 */
public class CountyCollection extends Entity {

	public CountyCollection() {
		super();
		select();
	}

	public CountyCollection(int countryId) {
		super();
		setCountryId(countryId);
		select();
	}

	public void setCountryId(int value) {
		setValue("countryId", value);
	}

	public int getCollectionSize() {
		return getCollectionSize("counties");
	}

	public int getId(int index) {
		return getCollectionIntValue("counties", "id", index);
	}

	public County getCounty(int index) {
		return new County(getId(index));
	}

}
